package com.example.loginapp;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import androidx.appcompat.app.AppCompatActivity;

public class SuccessActivity extends AppCompatActivity {
    Button btn_rv;
    Button btn_fr;
    Button btn_setting;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_success);

        btn_rv = findViewById(R.id.rv);
        btn_rv.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
//                Toast.makeText(SuccessActivity.this, "我点击了", Toast.LENGTH_SHORT).show();
                Intent intent = new Intent();
                intent.setClass(SuccessActivity.this,RecyclerViewActivity.class);
                startActivity(intent);
            }
        });

        btn_fr = findViewById(R.id.fr);
        btn_fr.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
//                Toast.makeText(SuccessActivity.this, "我点击了", Toast.LENGTH_SHORT).show();
                Intent intent = new Intent();
                intent.setClass(SuccessActivity.this,HomeActivity.class);
                startActivity(intent);
            }
        });

        btn_setting = findViewById(R.id.setting);
        btn_setting.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
//                Toast.makeText(SuccessActivity.this, "我点击了", Toast.LENGTH_SHORT).show();
                Intent intent = new Intent();
                intent.setClass(SuccessActivity.this,SetttingActivity.class);
                startActivity(intent);
            }
        });

        Button exit = findViewById(R.id.exit);
        exit.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
//                Toast.makeText(SuccessActivity.this, "我点击了", Toast.LENGTH_SHORT).show();
                Intent intent = new Intent();
                intent.setClass(SuccessActivity.this,MainActivity.class);
                startActivity(intent);
            }
        });
    }
}